@include('layouts.Common.header')


<div class="card">



    <div class="card-footer  nr-other">
        <div class="btn-group">
            <button id=ajaxdata class="btn btn-default">保存</button>
            <button id=reloaddd class="btn btn-default">同步部门用户</button>
        </div>
    </div>

    <form name="actionForm" id="actionForm" method="post">
        @csrf
        <input type="dosubmit" id="dosubmit" name="dosubmit" hidden />

        <div class="row">
            <div class="col-md-12  nr-form">
                <div class="card-body">
                    {{-- <div class="form-group">
                        <label for="agentId">[必填]企业 AgentId</label>
                        <input type="text" class="form-control" name=data[agentId]
                            value="{{ isset($agentId) ? $agentId : '' }}" id="agentId">
                    </div> --}}
                    <div class="form-group">
                        <label for="corp_id">[必填]企业 corpId</label>
                        <input type="text" class="form-control" name=data[corp_id]
                            value="{{ isset($corp_id) ? $corp_id : '' }}" id="corp_id">
                    </div>
                    <div class="form-group">
                        <label for="sso_secret">[选填]管理后台免登sso_secret</label>
                        <input type="text" class="form-control" name=data[sso_secret]
                            value="{{ isset($sso_secret) ? $sso_secret : '' }}" id="sso_secret">
                    </div>
                    {{-- <div class="form-group">
                        <label for="app_key">[必填]应用 AppKey</label>
                        <input type="text" class="form-control" name=data[app_key]
                            value="{{ isset($app_key) ? $app_key : '' }}" id="app_key">
                    </div>
                    <div class="form-group">
                        <label for="app_secret">[必填]应用 AppSecret</label>
                        <input type="text" class="form-control" name=data[app_secret]
                            value="{{ isset($app_secret) ? $app_secret : '' }}" id="app_secret">
                    </div>
                    <div class="form-group">
                        <label for="token">[选填]加解密token</label>
                        <input type="text" class="form-control" name=data[token]
                            value="{{ isset($token) ? $token : '' }}" id="token">
                    </div>
                    <div class="form-group">
                        <label for="aes_key">[选填]加解密aes_key</label>
                        <input type="text" class="form-control" name=data[aes_key]
                            value="{{ isset($aes_key) ? $aes_key : '' }}" id="aes_key">
                    </div>
                   

                    <div class="form-group">
                        <div class="form-check" style="padding:0px">
                            <label for="logenable">[选填]日志启用</label>

                            <input type="checkbox" class="form-check-input" style="margin-left:5px" name=data[logenable]
                                {{ $logenable == 1 ? 'checked' : '' }} id="logenable">
                        </div>
                    </div>
                    <div class="form-group">
                        <label for="logpath">[选填]日志目录</label>
                        <input type="text" class="form-control" name=data[logpath]
                            value="{{ isset($logpath) ? $logpath : '' }}" id="logpath">
                    </div> --}}

                </div>
            </div>
            <!-- /.card-body -->
            <div class="col-md-12">
                <div class="card-body">
                    <div class="nr-toolbar btn-group">
                    </div>
                    <div class="nr-grid">
                    </div>

                    <script>
                        var fg = {!! json_encode($fg) !!};
                        var toolbar = {!! json_encode($toolbar) !!};
                        var items = {!! json_encode(isset($items) ? $items : []) !!};
                        var subgrid = {!! json_encode(isset($subgrid) ? $subgrid : []) !!};
                        $(".nr-grid").initgridEdit(fg);
                        $(".nr-toolbar").toolbarEdit({
                            'toolbar': toolbar
                        });

                        $(".nr-toolbar").toolbarEdit("addRowData", items);
                        $.subGrid(subgrid, 'subGridRowExpanded', "jqgrid_items");
                    </script>
                </div>
            </div>
        </div>
    </form>
</div>
{!! js() !!}
